-- card: 14916 from stack: in.2r -- bmap block id: 0 -- flags: 4000 -- background id: 2202 -- name: GetFullPath ----- HyperTalk script ----- function GetFullPath name,pathlist repeat with i = 1 to the number of lines in pathlist if line i of pathlist is empty then next repeat -- sanity check put line i of pathlist & name into fname if FileModDate(fname,true) is not empty then -- found it return fname end if end repeat return empty -- file not found in pathlist end GetFullPath -- part contents for background part 10 ----- text ----- 2 -- part contents for background part 2 ----- text ----- -- -- GetFullPath: a function to find the full path name of an application, -- document or stack. The pathlist is one of 3 globals: applications, -- documents or stacks- see getHomeInfo in the Home stack's stack script -- For instance: -- global stacks -- put GetFullPath("Browser",stacks) into bpath -- should compute the full pathname of the Browser stack (if the "Look -- for stacks in:" card in the Home stack is up to date). -- function GetFullPath name,pathlist repeat with i = 1 to the number of lines in pathlist if line i of pathlist is empty then next repeat -- sanity check put line i of pathlist & name into fname if FileModDate(fname,true) is not empty then -- found it return fname end if end repeat return empty -- file not found in pathlist end GetFullPath -- part contents for background part 3 ----- text ----- GetFullPath